Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Forward console logs from the story context to the user's CLI #790

Merged
merged 2 commits into from
Jul 24, 2023

Conversation

Mike-Dax
Copy link
Contributor

@Mike-Dax Mike-Dax commented Jul 24, 2023

This builds on #789, happy to rebase as needed.

Currently the screenshot utility swallows all console logs and errors from the 'story' context. This makes debugging screenshots extremely difficult. (It's also quite difficult to mount a debugger to the internal story isolate.)

This PR forwards console messages by default into the debug Logger channel, and optionally allows for a --forwardConsoleLogs option to surface them to the user's CLI with matched error, warn or info log levels.

Messages currently look like:

error From examples-thrusttestbench--screenshot-light (error): THREE.WebGLRenderer: Error creating WebGL context.

image

Happy to bikeshed the cli option name, format of the logs, etc.

@Quramy Quramy merged commit a226224 into reg-viz:master Jul 24, 2023
@Mike-Dax Mike-Dax deleted the forward-console branch July 25, 2023 00:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants